package fr.cephb.mapreduce;

import org.apache.hadoop.io.IntWritable;
import org.apache.hadoop.io.LongWritable;
import org.apache.hadoop.io.Text;
import org.apache.hadoop.mapreduce.Mapper;


public class CodingSnpMapper
	extends Mapper<LongWritable, Text, Text, IntWritable>
	{
	@Override
	public void map(LongWritable key, Text value, org.apache.hadoop.mapreduce.Mapper<LongWritable,Text,Text,IntWritable>.Context context) throws java.io.IOException ,InterruptedException
		{
		String tokens[]=value.toString().split("[\t]");
		String chrom=tokens[1];
		context.write(new Text(chrom), new IntWritable(1));
		};
	}
